﻿<UserControl
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
	xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	mc:Ignorable="d"
	x:Class="urBook.Gui.GroupItem"
	x:Name="UserControl">
    <UserControl.ContextMenu>
        <ContextMenu>
            <MenuItem Header="Rename" Click="Rename"/>
            <MenuItem Header="Delete" Click="Delete"/>
            <MenuItem Header="Apply photo to Contacts" Click="ApplyGroupPhoto"/>
        </ContextMenu>
    </UserControl.ContextMenu>
    <Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
        <Image x:Name="GroupImage" Source="images/unknownGroup.png" Margin="8" 
            HorizontalAlignment="Left" Height="32" VerticalAlignment="Center" Width="32" MouseLeftButtonDown="GroupImage_MouseLeftButtonDown"/>
        <Label x:Name="GroupName" Content="All Contacts" Margin="48,8,32,8"
            HorizontalAlignment="Left" VerticalAlignment="Center" 
            FontSize="16" ToolTip="Group Name" MouseDoubleClick="GroupName_MouseDoubleClick"/>
        <TextBox x:Name="GroupRename" Text="All Contacts" Margin="48,8,32,8"
            HorizontalAlignment="Left" VerticalAlignment="Center" VerticalContentAlignment="Center"
            Visibility="Collapsed" FontStretch="Normal" FontSize="16" KeyDown="GroupRename_KeyDown" MouseDown="GroupRename_MouseDown"/>
        <Image Height="16" HorizontalAlignment="Right" Margin="8" Name="delete" Source="data/images/delete_32.png" VerticalAlignment="Center" Width="16" MouseLeftButtonDown="delete_MouseDown"/>
    </Grid>
</UserControl>